<!-- 主页面 -->
<template>
  <div class="home">
    <navBar></navBar>
    <!-- 动态路由，切换组件(切换子页面) -->
    <router-view v-slot="{ Component }" >
        <component :is="Component" class="content" />
    </router-view>
  </div>
</template>

<script>
// 引入导航栏组件
import navBar from "@/components/navBar.vue";
export default {
  name: "HomeView",
  components: {
    navBar,
  },
};
</script>
<style lang="less" scoped>
// 主页面的尺寸控制
.home {
  min-height: 100vh;
  width: 100vw;
  background-color: #1a2a3c;
  align-items: center;
  .content {
    overflow: hidden auto;
    &::-webkit-scrollbar {
      display: none; /* 隐藏滚动条 */
    }
  }
}
</style>
